package ExperimentFour.Strategy;

/**
 * @author 北巷_东坡
 * @date 2022/11/15 19:53
 * @computer 10741
 */
public class Client206 {
    public static void main(String[] args) {
        int a = 50;   // 电影院票价
        CinemaTicketSales206 cinemaTicketSales206=new CinemaTicketSales206();
        Discount206 discount206;
        discount206 = (Discount206) XMLUtil.getBean("stu");
        cinemaTicketSales206.setDiscount206(discount206);
        int result = discount206.doDiscount(a);
        System.out.println("折后价为："+result);
        System.out.println("-----------------------------------");
        discount206 = (Discount206) XMLUtil.getBean("vip");
        cinemaTicketSales206.setDiscount206(discount206);
        int result1 = discount206.doDiscount(a);
        System.out.println("折后价为："+result1);
    }
}
